#include "syscall.h"

int
main ()
{
    int newProc;
    OpenFileId input = ConsoleInput;
    OpenFileId output = ConsoleOutput;
    char prompt[2], ch, buffer[60];
    int i;

    prompt[0] = '-';
    prompt[1] = '-';

    while (1)
      {
	  PutString (prompt);

	  i = 0;

	  do
	    {

		buffer[i] = GetChar();

	    }
	  while (buffer[i++] != '\n');

	  buffer[--i] = '\0';

	  if (i > 0)
	    {
		newProc = ForkExec (buffer);
		UserForkJoin (newProc);
	    }
      }
}
